package com.yl.projects.adapter

import androidx.fragment.app.Fragment
import androidx.viewpager2.adapter.FragmentStateAdapter

/**
 * Created by stew on 8/5/22.
 */
class ProjectAdapter(context: Fragment, private val fragnentList: ArrayList<Fragment>) :
    FragmentStateAdapter(context) {

    override fun getItemCount(): Int {
        return fragnentList.size
    }

    override fun createFragment(position: Int): Fragment {
        return fragnentList[position]
    }
}